/**
 *
 * 版权所有 © cybersky.com
 *
 */
package cn.cybertron.primus.report.entity;

import java.io.Serializable;

/**
 * 报表页面设置类
 * @author: ch
 */
public class ReportPage implements Serializable {

	private static final long serialVersionUID = -1881971186485898251L;

	/**
	 * 纸张大小
	 */
	public static enum Size {
		
		A3(842, 1190), A4(595, 842);
		
		int width;
		
		int height;
		
		Size(int width, int height) {
			this.width = width;
			this.height = height;
		}
		
		public int getWidth() {
			return width;
		}
		
		public int getHeight() {
			return height;
		}
	}

	/**
	 * 纸张方向
	 */
	public static enum Orientation {
		vertical /* 垂直 */, horizontal /* 水平 */
	}

	/**
	 * 页面大小，缺省A4幅
	 */
	protected Size size = Size.A4;
	
	/**
	 * 页面方向，缺省纵向
	 */
	protected Orientation orientation = Orientation.vertical;

	/**
	 * 报表页眉设置，缺省无。允许有多个元素
	 */
	protected ReportDecoration[] header;
	
	/**
	 * 报表页脚设置，缺省无。允许有多个元素
	 */
	protected ReportDecoration[] footer;

	public ReportPage() {

	}

	public Size getSize() {
		return size;
	}

	public void setSize(Size size) {
		this.size = size;
	}

	public Orientation getOrientation() {
		return orientation;
	}

	public void setOrientation(Orientation orientation) {
		this.orientation = orientation;
	}

	public ReportDecoration[] getHeader() {
		return header;
	}

	public void setHeader(ReportDecoration... header) {
		this.header = header;
	}

	public ReportDecoration[] getFooter() {
		return footer;
	}

	public void setFooter(ReportDecoration... footer) {
		this.footer = footer;
	}
	
}
